Root Object
Modified on 2011/04/04 14:05 by Charles — Categorized as: Jetfire Language
When a
workflow
is created it can optionally be made a 'root' object. Making an object root prevents the garbage collector from reclaiming resources used by workflow, even if there are no references to the workflow. A 'root' object will exist forever, surviving program shutdowns.
It is practice in Jetfire programs to make long lived objects 'root' and not rely on references from another object such as collection (eg: Array, List, Dictionary, etc.). Objects that represent a 'user' are typically made 'root'.
All objects created directly by the
application interface
are automatically root.
Workflow
s created pro-grammatically, by default, are not root objects and will be reclaimed by the garbage collector if they have not reference.